package org.csu.question.entity.dto;

import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

@Data
public class SubmitAnswerRequest {
    @NotNull(message = "用户ID不能为空")
    private Long userId;

    @NotNull(message = "题目ID不能为空")
    private Long questionId;

    @NotBlank(message = "用户答案不能为空")
    private String userAnswer;

    @Min(value = 0, message = "答题时间不能为负数")
    private Integer timeCost; // 答题耗时(秒)
}
